package com.tyk.bookstore.back.order.model.enume;


import com.fasterxml.jackson.annotation.JsonValue;
import com.tyk.bookstore.back.common.core.model.type.BaseEnum;

/**
 * @author tyk
 * @description 订单取消原因
 */
public enum CancelReason implements BaseEnum {

    OTHER(0),
    NO_STOCK(1),
    EXPENSIVE(2),
    PRICE_REDUCE(3),
    FORMAT_ERROR(4),
    ADDRESS_ERROR(5),
    NO_NEED(6),
    OVERTIME_UNPAID(7);

    @JsonValue
    private final Integer code;

    @Override
    public Integer value() {
        return this.code;
    }

    CancelReason(Integer code) {
        this.code = code;
    }
}
